#include <iostream>
#include <cstdio>
#include <cstring>
using namespace std;
typedef long long LL;
LL C(LL a, LL b) {
	if (b==0) return 1ll;
	if (b<0 || b>a) return 0;
	LL ans=1;
	for (LL i=0; i<b; ++i) {
		ans=ans*(a-i)/(i+1);
	}
//	cout<<ans<<endl;
	return ans;
}
int main() {
    #ifdef hai
    freopen("in.txt", "r", stdin);
    #endif
	LL ask;
	LL cas=1;
	while (cin>>ask&&ask) {
		if (ask%2==1 || ask<4) printf("Case %lld: 0\n", cas);
//		else if (ask==4) printf("Case %d: %d\n", cas, 1);
		else printf("Case %lld: %lld\n", cas, C((ask+4)/2+1, 5)-C((ask+4)/2-1, 5));
		++cas;
	}
	return 0;
} 
